900 |
How can I prevent a link to end to a specified bar
With G2antt1 .BeginUpdate .Columns.Add "Tasks" With .Chart .AllowLinkBars = True .LevelCount = 2 .PaneWidth(0) = 160 .FirstVisibleDate = #6/20/2005# End With With .Items h = .AddItem("Not-End-Linkable") .AddBar h,"Unknown",#6/21/2005#,#6/28/2005# .ItemBar(h,"",31) = False .AddBar .AddItem("Task 1"),"Task",#6/23/2005#,#6/27/2005#,"" .AddBar .AddItem("Task 2"),"Task",#6/23/2005#,#6/27/2005#,"" End With .EndUpdate End With |
899 |
How can I prevent a link to start from a specified bar
With G2antt1 .BeginUpdate .Columns.Add "Tasks" With .Chart .AllowLinkBars = True .LevelCount = 2 .PaneWidth(0) = 160 .FirstVisibleDate = #6/20/2005# End With With .Items h = .AddItem("Not-Start-Linkable") .AddBar h,"Unknown",#6/21/2005#,#6/28/2005# .ItemBar(h,"",30) = False .AddBar .AddItem("Task 1"),"Task",#6/23/2005#,#6/27/2005#,"" .AddBar .AddItem("Task 2"),"Task",#6/23/2005#,#6/27/2005#,"" End With .EndUpdate End With |
898 |
How can I prevent a specified bar to be linked
With G2antt1 .BeginUpdate .Columns.Add "Tasks" With .Chart .AllowLinkBars = True .LevelCount = 2 .PaneWidth(0) = 160 .FirstVisibleDate = #6/20/2005# End With With .Items h = .AddItem("Not-Linkable") .AddBar h,"Unknown",#6/21/2005#,#6/28/2005# .ItemBar(h,"",32) = False .AddBar .AddItem("Task 1"),"Task",#6/23/2005#,#6/27/2005#,"" .AddBar .AddItem("Task 2"),"Task",#6/23/2005#,#6/27/2005#,"" End With .EndUpdate End With |
897 |
How can I display in the chart's header only days where the week starts
With G2antt1 With .Chart .PaneWidth(0) = 0 .FirstVisibleDate = #1/31/2009# .LevelCount = 2 .FirstWeekDay = 1 With .Level(0) .Label = "<%mmmm%> <%yyyy%>" .Alignment = 1 .Unit = 16 End With With .Level(1) .Unit = 4096 .FormatLabel = " (0:=weekday(dvalue)) = 1 ? '<b>' +value : '' " End With .UnitWidth = 23 End With End With |
896 |
Is there any automatically way to display and change the bar's duration in the columns section
With G2antt1 .BeginUpdate .MarkSearchColumn = False With .Columns .Add "Tasks" With .Add("Duration") .Def(18) = 513 .Editor.EditType = 4 End With End With With .Chart .LevelCount = 2 .FirstVisibleDate = #1/1/2009# End With With .Items .AllowCellValueToItemBar = True .AddBar .AddItem("Task 1"),"Task",#1/2/2009#,#1/7/2009# .AddBar .AddItem("Task 2"),"Task",#1/4/2009#,#1/9/2009# End With .EndUpdate End With |
895 |
How can I programatically move or resize a bar using spin or slider controls in the columns
With G2antt1 .BeginUpdate .MarkSearchColumn = False With .Columns .Add "Tasks" With .Add("Start") .Def(18) = 1 .Editor.EditType = 4 End With With .Add("End") .Def(18) = 2 .Editor.EditType = 4 End With End With With .Chart .LevelCount = 2 .ShowEmptyBars = 1 .FirstVisibleDate = #1/1/2009# End With With .Items .AllowCellValueToItemBar = True .AddBar .AddItem("Task 1"),"Task",#1/2/2009#,#1/7/2009# .AddBar .AddItem("Task 2"),"Task",#1/4/2009#,#1/9/2009# End With .EndUpdate End With |
894 |
I am trying to call the ItemBar(exBarStart) after curent ending point, and the bar is not updated. What I am doing wrong
With G2antt1 .BeginUpdate .Columns.Add "Tasks" With .Chart .PaneWidth(0) = 64 .FirstVisibleDate = #6/21/2005# .ShowEmptyBars = 1 End With With .Items h = .AddItem("Test") .AddBar h,"Task",#6/22/2005#,#6/26/2005#,"" .AddBar h,"Task",#6/27/2005#,.ItemBar(h,"",2) End With .EndUpdate End With |
893 |
How can change in the same time the starting and ending points of the bar
With G2antt1 .BeginUpdate .Columns.Add "Tasks" With .Chart .PaneWidth(0) = 64 .FirstVisibleDate = #6/21/2005# .ShowEmptyBars = 1 End With With .Items h = .AddItem("Test") .AddBar h,"Task",#6/22/2005#,#6/26/2005# End With With .Items h = .FirstVisibleItem .AddBar h,"Task",#6/27/2005#,#6/29/2005# End With .EndUpdate End With |
892 |
How can I control the exBarEffort property of the bar using slider controls
With G2antt1 .BeginUpdate .MarkSearchColumn = False .ShowFocusRect = False .OnResizeControl = 1 .Columns.Add("Tasks").AllowDragging = False With .Columns.Add("Histogram") .AllowDragging = False .Def(0) = True .PartialCheck = True .AllowSizing = False .Width = 18 .LevelKey = 1 End With .Items.AllowCellValueToItemBar = True With .Columns.Add("Effort") .LevelKey = 1 .AllowDragging = False .AllowSizing = False .Width = 64 .Def(18) = 21 With .Editor .EditType = 20 .Option(41) = -100 .Option(44) = 9 .Option(43) = 1 End With End With With .Chart .LevelCount = 3 .NonworkingDays = 0 .PaneWidth(0) = 160 .FirstVisibleDate = #6/20/2005# .HistogramVisible = True .HistogramView = 67348 ' &H10000 Or HistogramViewEnum.exHistogramNoGrouping Or HistogramViewEnum.exHistogramRecLeafItems Or HistogramViewEnum.exHistogramLeafItems Or HistogramViewEnum.exHistogramUnlockedItems Or HistogramViewEnum.exHistogramCheckedItems .HistogramHeight = 64 With .Bars.Item("Task") .HistogramCriticalColor = RGB(255,0,0) .HistogramPattern = 512 .HistogramType = 1 End With End With With .Items h = .AddItem("Project 1") .AddBar h,"Summary",#6/21/2005#,#7/1/2005# .CellEditorVisible(h,2) = False .CellValue(h,2) = "" h1 = .InsertItem(h,,"Task 1") .AddBar h1,"Task",#6/21/2005#,#6/28/2005# .CellMerge(h1,0) = 1 .DefineSummaryBars h,"",h1,"" h1 = .InsertItem(h,,"Task 2") .AddBar h1,"Task",#6/23/2005#,#7/1/2005#,"" .CellMerge(h1,0) = 1 .DefineSummaryBars h,"",h1,"" .ItemBar(h1,"",21) = 5 h1 = .InsertItem(h,,"Task 3") .AddBar h1,"Task",#6/25/2005#,#6/27/2005#,"" .CellMerge(h1,0) = 1 .DefineSummaryBars h,"",h1,"" .ExpandItem(h) = True .CellState(h,1) = 1 h = .AddItem("Project 2") .AddBar h,"Summary",#3/7/2005#,#7/12/2005# .CellEditorVisible(h,2) = False .CellValue(h,2) = "" h1 = .InsertItem(h,,"Task 1") .AddBar h1,"Task",#7/3/2005#,#7/8/2005# .CellMerge(h1,0) = 1 .DefineSummaryBars h,"",h1,"" h1 = .InsertItem(h,,"Task 2") .AddBar h1,"Task",#7/5/2005#,#7/12/2005#,"" .CellMerge(h1,0) = 1 .DefineSummaryBars h,"",h1,"" .ItemBar(h1,"",21) = 5 h1 = .InsertItem(h,,"Task 3") .AddBar h1,"Task",#7/7/2005#,#7/8/2005#,"" .CellMerge(h1,0) = 1 .DefineSummaryBars h,"",h1,"" .ExpandItem(h) = True .CellState(h,1) = 1 End With .EndUpdate End With |
891 |
How can I determine if there is any Redo operation
With G2antt1 With .Chart .AllowUndoRedo = True .LevelCount = 2 .FirstVisibleDate = #1/1/2001# End With .Columns.Add "Column" With .Items .AddBar .AddItem("Item 1"),"Task",#1/2/2001#,#1/4/2001# .AddBar .AddItem("Item 2"),"Task",#1/3/2001#,#1/7/2001# End With var_CanRedo = .Chart.CanRedo End With |
890 |
How can I determine if there is any Undo operation
With G2antt1 With .Chart .AllowUndoRedo = True .LevelCount = 2 .FirstVisibleDate = #1/1/2001# End With .Columns.Add "Column" With .Items .AddBar .AddItem("Item 1"),"Task",#1/2/2001#,#1/4/2001# .AddBar .AddItem("Item 2"),"Task",#1/3/2001#,#1/7/2001# End With var_CanUndo = .Chart.CanUndo End With |
889 |
How can I turn on the Undo/Redo feature
With G2antt1 With .Chart .AllowUndoRedo = True .LevelCount = 2 .FirstVisibleDate = #1/1/2001# End With .Columns.Add "Column" With .Items .AddBar .AddItem("Item 1"),"Task",#1/2/2001#,#1/4/2001# .AddBar .AddItem("Item 2"),"Task",#1/3/2001#,#1/7/2001# End With End With |
888 |
How can I disable resizing the histogram at runtime
With G2antt1 .OnResizeControl = 256 With .Chart .FirstVisibleDate = #1/1/2001# .HistogramVisible = True .HistogramHeight = 32 .Bars.Item("Task").HistogramPattern = 6 End With .Columns.Add "Column" With .Items .AddBar .AddItem("Item 1"),"Task",#1/2/2001#,#1/4/2001# .AddBar .AddItem("Item 2"),"Task",#1/3/2001#,#1/7/2001# End With End With |
887 |
How can I display automatically the start and end dates of the bars in the columns section
With G2antt1 .BeginUpdate With .Columns .Add "Tasks" With .Add("Start") .Def(18) = 1 .Editor.EditType = 7 End With With .Add("End") .Def(18) = 2 .Editor.EditType = 7 End With End With With .Chart .FirstVisibleDate = #9/20/2006# .AllowLinkBars = True .AllowCreateBar = 0 .LevelCount = 2 .PaneWidth(0) = 196 End With With .Items .AllowCellValueToItemBar = True .AddBar .AddItem("Task 1"),"Task",#9/21/2006#,#9/24/2006# .AddBar .AddItem("Task 2"),"Task",#9/22/2006#,#9/25/2006# .AddBar .AddItem("Task 3"),"Task",#9/23/2006#,#9/26/2006# End With .EndUpdate End With |
886 |
How can I enable Undo/Redo support
With G2antt1 .BeginUpdate .MarkSearchColumn = False .DrawGridLines = 1 With .Columns .Add "Tasks" With .Add("Start") .Def(18) = 1 .Editor.EditType = 7 .LevelKey = 1 End With With .Add("End") .Def(18) = 2 .Editor.EditType = 7 .LevelKey = 1 End With End With With .Chart .DrawGridLines = 1 .FirstVisibleDate = #9/20/2006# .AllowLinkBars = True .AllowCreateBar = 0 .LevelCount = 2 .PaneWidth(0) = 196 .AllowUndoRedo = True End With With .Items .AllowCellValueToItemBar = True .AddBar .AddItem("Task 1"),"Task",#9/21/2006#,#9/24/2006# .AddBar .AddItem("Task 2"),"Task",#9/22/2006#,#9/25/2006# .AddBar .AddItem("Task 3"),"Task",#9/23/2006#,#9/26/2006# End With .EndUpdate End With |
885 |
Is there any option to update the bar's properties once the cell's value is changed ( associate the cell with bar )
With G2antt1 .BeginUpdate .Debug = True .MarkSearchColumn = False .Items.AllowCellValueToItemBar = True With .Columns .Add "Tasks" .Add("Start").Editor.EditType = 7 .Add("End").Editor.EditType = 7 .Add "Info" End With With .Chart .FirstVisibleDate = #9/20/2006# .AllowLinkBars = False .AllowCreateBar = 0 .LevelCount = 2 .PaneWidth(0) = 224 End With With .Items h1 = .InsertItem(,,"Task 1") .AddBar h1,"Task",#9/21/2006#,#9/23/2006#,"A","Caption" .ItemBar(h1,"A",4) = 18 .CellEditor(h1,3).EditType = 1 .CellValueToItemBar h1,1,1,"A" .CellValueToItemBar h1,2,2,"A" .CellValueToItemBar h1,3,3,"A" h2 = .InsertItem(,,"Task 2") .AddBar h2,"Task",#9/22/2006#,#9/24/2006#,"B" With .CellEditor(h2,3) .EditType = 20 .Option(41) = -100 End With .CellValueToItemBar h2,1,1,"B" .CellValueToItemBar h2,2,2,"B" .CellValueToItemBar h2,3,19,"B" h3 = .InsertItem(,,"Task 3") .AddBar h3,"Task",#9/23/2006#,#9/25/2006#,"C" With .CellEditor(h3,3) .EditType = 2 .AddItem 0,"Task" .AddItem 1,"Progress" .AddItem 2,"Project Summary" .AddItem 2,"Summary" End With .CellValueToItemBar h3,1,1,"C" .CellValueToItemBar h3,2,2,"C" .CellValueToItemBar h3,3,0,"C" End With .EndUpdate End With |
884 |
Is there any option to update the bar's properties once the cell's value is changed ( associate the column/cell with bars )
With G2antt1 .BeginUpdate .MarkSearchColumn = False .Indent = 11 .HasLines = 1 .Items.AllowCellValueToItemBar = True With .Columns .Add "Tasks" With .Add("Start") .Def(18) = 1 .Editor.EditType = 7 .LevelKey = 1 End With With .Add("End") .Def(18) = 2 .Editor.EditType = 7 .LevelKey = 1 End With With .Add("Transparency") .Def(18) = 19 With .Editor .EditType = 20 .Option(41) = -100 End With End With End With With .Chart .FirstVisibleDate = #9/20/2006# .AllowLinkBars = False .AllowCreateBar = 0 .LevelCount = 2 .PaneWidth(0) = 224 End With With .Items h = .AddItem("Project") .AddBar h,"Summary",#9/21/2006#,#10/3/2006# .CellEditorVisible(h,1) = False .CellEditorVisible(h,2) = False h1 = .InsertItem(h,,"Task 1") .AddBar h1,"Task",#9/21/2006#,#9/24/2006# h2 = .InsertItem(h,,"Task 2") .AddBar h2,"Task",#9/24/2006#,#9/28/2006# h3 = .InsertItem(h,,"Task 3") .AddBar h3,"Task",#9/28/2006#,#10/3/2006# .DefineSummaryBars h,"",h1,"" .DefineSummaryBars h,"",h2,"" .DefineSummaryBars h,"",h3,"" .ExpandItem(h) = True .ItemBold(h) = True End With .EndUpdate End With |
883 |
How can I group two bars so I can specify the range or the limit of the interval between them
With G2antt1 .BeginUpdate .MarkSearchColumn = False .OnResizeControl = 1 .Columns.Add "Tasks" .Columns.Add("Start").Visible = False .Columns.Add("End").Visible = False With .Chart .FirstVisibleDate = #9/20/2006# .PaneWidth(0) = 64 End With With .Items h = .AddItem("Project") .CellValue(h,1) = #9/21/2006# .CellValue(h,2) = #10/3/2006# .AddBar h,"Summary",.CellValue(h,1),.CellValue(h,2),"sum" h1 = .InsertItem(h,,"Task 1") .CellValue(h1,1) = .CellValue(h,1) .CellValue(h1,2) = #9/24/2006# .AddBar h1,"Task",.CellValue(h1,1),.CellValue(h1,2),"K1" h2 = .InsertItem(h,,"Task 2") .CellValue(h2,1) = .CellValue(h1,2) .CellValue(h2,2) = #9/28/2006# .AddBar h2,"Unknown",.CellValue(h2,1),.CellValue(h2,2),"K2" .AddLink "L1",h1,"K1",h2,"K2" h3 = .InsertItem(h,,"Task 3") .CellValue(h3,1) = .CellValue(h2,2) .CellValue(h3,2) = .CellValue(h,2) .AddBar h3,"Task",.CellValue(h3,1),.CellValue(h3,2),"K3" .AddLink "L2",h2,"K2",h3,"K3" .GroupBars h1,"K1",False,h2,"K2",True,31,"0;4" .GroupBars h2,"K2",False,h3,"K3",True,31,"0;2" .DefineSummaryBars h,"sum",h1,"K1" .DefineSummaryBars h,"sum",h2,"K2" .DefineSummaryBars h,"sum",h3,"K3" .ExpandItem(h) = True .ItemBold(h) = True End With .EndUpdate End With |
882 |
How can I group my bars so I can resize the interval between them but still keep the lengths of them
With G2antt1 .BeginUpdate .MarkSearchColumn = False .OnResizeControl = 1 .Columns.Add "Tasks" .Columns.Add("Start").Visible = False .Columns.Add("End").Visible = False With .Chart .FirstVisibleDate = #9/20/2006# .PaneWidth(0) = 64 End With With .Items h = .AddItem("Project") .CellValue(h,1) = #9/21/2006# .CellValue(h,2) = #10/3/2006# .AddBar h,"Summary",.CellValue(h,1),.CellValue(h,2) h1 = .InsertItem(h,,"Task 1") .CellValue(h1,1) = .CellValue(h,1) .CellValue(h1,2) = #9/24/2006# .AddBar h1,"Task",.CellValue(h1,1),.CellValue(h1,2) h2 = .InsertItem(h,,"Task 2") .CellValue(h2,1) = .CellValue(h1,2) .CellValue(h2,2) = #9/28/2006# .AddBar h2,"Unknown",.CellValue(h2,1),.CellValue(h2,2) .AddLink "L1",h1,"",h2,"" h3 = .InsertItem(h,,"Task 3") .CellValue(h3,1) = .CellValue(h2,2) .CellValue(h3,2) = .CellValue(h,2) .AddBar h3,"Task",.CellValue(h3,1),.CellValue(h3,2) .AddLink "L2",h2,"",h3,"" .GroupBars h1,"",False,h2,"",True,35 .GroupBars h2,"",False,h3,"",True,35 .DefineSummaryBars h,"",h1,"" .DefineSummaryBars h,"",h2,"" .DefineSummaryBars h,"",h3,"" .ExpandItem(h) = True .ItemBold(h) = True End With .EndUpdate End With |
881 |
Can I group my bars so they move together when a bar inside changes, but still preserving the length of the bars
With G2antt1 .BeginUpdate .MarkSearchColumn = False .OnResizeControl = 1 .Columns.Add "Tasks" .Columns.Add("Start").Visible = False .Columns.Add("End").Visible = False With .Chart .FirstVisibleDate = #9/20/2006# .PaneWidth(0) = 64 End With With .Items h = .AddItem("Project") .CellValue(h,1) = #9/21/2006# .CellValue(h,2) = #10/3/2006# .AddBar h,"Summary",.CellValue(h,1),.CellValue(h,2) h1 = .InsertItem(h,,"Task 1") .CellValue(h1,1) = .CellValue(h,1) .CellValue(h1,2) = #9/24/2006# .AddBar h1,"Task",.CellValue(h1,1),.CellValue(h1,2) h2 = .InsertItem(h,,"Task 2") .CellValue(h2,1) = .CellValue(h1,2) .CellValue(h2,2) = #9/28/2006# .AddBar h2,"Unknown",.CellValue(h2,1),.CellValue(h2,2) .AddLink "L1",h1,"",h2,"" h3 = .InsertItem(h,,"Task 3") .CellValue(h3,1) = .CellValue(h2,2) .CellValue(h3,2) = .CellValue(h,2) .AddBar h3,"Task",.CellValue(h3,1),.CellValue(h3,2) .AddLink "L2",h2,"",h3,"" .GroupBars h1,"",False,h2,"",True,3 .GroupBars h2,"",False,h3,"",True,3 .DefineSummaryBars h,"",h1,"" .DefineSummaryBars h,"",h2,"" .DefineSummaryBars h,"",h3,"" .ExpandItem(h) = True .ItemBold(h) = True End With .EndUpdate End With |
880 |
How can I split the time scale, so a section displays days, while other displays weeks, and the other months
With G2antt1 .BeginUpdate .HeaderHeight = 24 .Columns.Add "Default" With .Chart .DrawDateTicker = True .DrawGridLines = 2 .NonworkingDays = 0 .PaneWidth(0) = 0 .FirstVisibleDate = #1/1/2007# .LevelCount = 3 With .Level(0) .Label = "<%yyyy%>" .Unit = 0 End With With .Level(1) .Alignment = 1 .Label = "<%hy%>" .Unit = 1 .ReplaceLabel("1") = "<b>1/2</b>" .ReplaceLabel("2") = "<b>2/2</b>" End With With .Level(2) .Label = "<%mmm%>" .Unit = 16 End With .UnitWidth = 28 .AllowInsideZoom = True With .DefaultInsideZoomFormat .OwnerLabel = "<b><%mmmm%></b> (weeks) " .InsideLabel = "<font ;6>W: <b><%ww%></b>" .InsideUnit = 256 End With With .InsideZooms .SplitBaseLevel = False With .Add(#1/1/2007#) .AllowCustomFormat = True With .CustomFormat .OwnerLabel = "<b><%mmmm%></b> (weeks) " .InsideLabel = "<font ;6>W: <b><%ww%></b>" .InsideUnit = 256 .BackColorChart = RGB(187,231,240) End With End With With .Add(#3/1/2007#) .AllowCustomFormat = True .Width = 356 With .CustomFormat .OwnerLabel = "<b><%mmmm%></b> (days) " .InsideLabel = "<font ;5><%d%></font>" .InsideUnit = 4096 .BackColorChart = RGB(145,200,240) End With End With End With End With With .Items h = .AddItem("Task 1 ") .AddBar h,"Task",#1/12/2007#,#3/9/2007# h = .AddItem("Task 2") .AddBar h,"Task",#1/25/2007#,#3/12/2007# h = .AddItem("Task 3") .AddBar h,"Task",#2/1/2007#,#2/8/2007#,"B1" .AddBar h,"Task",#2/8/2007#,#2/15/2007#,"B2" .AddBar h,"Task",#2/15/2007#,#2/22/2007#,"B3" .AddBar h,"Task",#2/22/2007#,#2/28/2007#,"B4" End With .EndUpdate End With |
879 |
How can I define a bar that shows two colors, one up and one down, without using skin or EBN files
With G2antt1 .BeginUpdate .Columns.Add "Task" .Chart.FirstVisibleDate = #1/1/2001# With .Chart.Bars.Add("A") .Color = RGB(255,0,0) .Shape = 2 .Pattern = 1 End With With .Chart.Bars.Add("B") .Color = RGB(128,0,0) .Shape = 4 .Pattern = 1 End With .Chart.Bars.Add("A%B").Shortcut = "AB" With .Items h = .AddItem("Task 1") .AddBar h,"AB",#1/2/2001#,#1/6/2001#,"K1" .ItemBar(h,"K1",12) = 1 .ItemBar(h,"K1",16) = False End With .EndUpdate End With |
878 |
Does your control support RightToLeft property for RTL languages or right to left
With G2antt1 .BeginUpdate .ScrollBars = 15 .LinesAtRoot = -1 With .Columns.Add("P1") .Def(0) = True .PartialCheck = True End With With .Items h = .AddItem("Root") .InsertItem h,,"Child 1" .InsertItem h,,"Child 2" .ExpandItem(h) = True End With .RightToLeft = True .EndUpdate End With |
877 |
Is there any way to display the vertical scroll bar on the left side, as I want to align my data to the right
With G2antt1 .BeginUpdate .ScrollBars = 15 With .Columns .Add "C1" .Add "C2" .Add "C3" .Add "C4" .Add "C5" .Add "C6" .Add "C7" .Add "C8" End With .RightToLeft = True .EndUpdate End With |
876 |
Can I display the cell's check box after the text
With G2antt1 With .Columns.Add("Column") .Def(0) = True .Def(34) = "caption,check" End With With .Items .CellHasCheckBox(.AddItem("Caption 1"),0) = True .CellHasCheckBox(.AddItem("Caption 2"),0) = True End With End With |
875 |
Can I change the order of the parts in the cell, as checkbox after the text, and so on
With G2antt1 .Images "gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTq" & _ "lVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m" & _ "0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/y" & _ "NAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=" .Columns.Add("Column").Def(34) = "caption,check,icon,icons,picture" With .Items h = .AddItem("Text") .CellImage(h,0) = 1 .CellHasCheckBox(h,0) = True End With End With |
874 |
Can I have an image displayed after the text. Can I get that effect without using HTML content
With G2antt1 .Images "gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTq" & _ "lVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m" & _ "0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/y" & _ "NAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=" .Columns.Add("Column").Def(34) = "caption,icon,check,icons,picture" With .Items h = .AddItem("Text") .CellImage(h,0) = 1 End With End With |
873 |
My problem is that I want to mark the cells from every second item in the gant with a other backgroundcolor
|
872 |
Is there any option to print the columns section on each page
With G2antt1 .BeginUpdate .Columns.Add "Col 1" .Columns.Add "Col 2" .MarkSearchColumn = False .Chart.FirstVisibleDate = #1/1/2001# .Chart.LevelCount = 2 With .Items h1 = .AddItem("Col 1") .CellValue(h1,1) = "Col 2" .AddBar h1,"Task",#1/2/2001#,#1/4/2001#,"K1" h2 = .AddItem("Col 1") .CellValue(h2,1) = "Col 2" .AddBar h2,"Task",#2/5/2001#,#2/7/2001#,"K2" .AddLink "L1",h1,"K1",h2,"K2" .Link("L1",6) = 0 End With .EndUpdate With CreateObject("Exontrol.Print") .Options = "ColumnsOnEveryPage=-2" .PrintExt = G2antt1.Object .Preview End With End With |
871 |
How can I add a different non-working area for different items
With G2antt1 .Columns.Add "Non-Work" With .Chart .FirstWeekDay = 1 .FirstVisibleDate = #1/24/2008# .PaneWidth(False) = 52 .LevelCount = 2 End With With .Items h = .AddItem("January") .ItemNonworkingUnits(h,False) = "month(value) = 1" h = .AddItem("February, Saturday, Sunday") .ItemNonworkingUnits(h,False) = "month(value) = 2 or (weekday(value) = 0 or weekday(value) = 6)" h = .AddItem("Sunday") .ItemNonworkingUnits(h,False) = "weekday(value) = 0" End With End With |
870 |
How can I define different non-working units for different items
With G2antt1 .BeginUpdate .Columns.Add "Tasks" With .Chart .PaneWidth(0) = 78 .AllowCreateBar = 1 .FirstVisibleDate = #6/20/2005# .DrawLevelSeparator = False .LevelCount = 3 .Level(1).DrawGridLines = False .AllowInsideZoom = True .DrawDateTicker = True .DateTickerLabel = "<%mmm%> <%d%><br><b><%hh%>:<%nn%></b>" .MarkSelectDateColor = &H7ffff8ee With .DefaultInsideZoomFormat .OwnerLabel = "<%mmm%> <%d%>" .BackColor = RGB(238,248,255) .BackColorChart = .BackColor .InsideCount = 4 .InsideLabel = "<b><%hh%></b>" End With .InsideZooms.Add #6/22/2005# .DrawGridLines = 2 .Bars.Item("Split").Color = RGB(255,0,0) With .Bars.Add("Task:Split") .Color = RGB(255,0,0) .Pattern = 6 .Shortcut = "TaskS" End With End With With .Items h = .AddItem("Project 1") .AddBar h,"Summary",#6/21/2005#,#7/1/2005# h1 = .InsertItem(h,,"Task 1") .AddBar h1,"TaskS",#6/21/2005#,#6/28/2005# .ItemNonworkingUnits(h1,False) = "weekday(value)=1 or weekday(value)=2" .ItemNonworkingUnits(h1,True) = "weekday(value)=1 or weekday(value)=2 or (hour(value)<8 or hour(value)>=16 )" .DefineSummaryBars h,"",h1,"" h1 = .InsertItem(h,,"Task 2") .AddBar h1,"TaskS",#6/22/2005 4:00:00 AM#,#7/1/2005#,"E" .ItemNonworkingUnits(h1,False) = "weekday(value)=0" .ItemNonworkingUnits(h1,True) = "weekday(value)=0 or hour(value)<4 or hour(value)>19" .DefineSummaryBars h,"",h1,"E" .ItemBar(h1,"E",21) = 5 h1 = .InsertItem(h,,"Task 3") .AddBar h1,"TaskS",#6/22/2005 0:00:00 PM#,#6/27/2005#,"E" .ItemNonworkingUnits(h1,False) = "weekday(value)=1 or weekday(value)=2" .ItemNonworkingUnits(h1,True) = "weekday(value)=1 or weekday(value)=2 or (hour(value)<8 or hour(value)>=16 )" .DefineSummaryBars h,"",h1,"E" .ExpandItem(h) = True h = .AddItem("Project 2") .AddBar h,"Summary",#6/26/2005#,#7/6/2005# h1 = .InsertItem(h,,"TaskS 1") .AddBar h1,"TaskS",#6/26/2005#,#7/2/2005# .DefineSummaryBars h,"",h1,"" h1 = .InsertItem(h,,"TaskS 2") .AddBar h1,"TaskS",#6/28/2005#,#7/6/2005#,"E" .DefineSummaryBars h,"",h1,"E" .ItemBar(h1,"E",21) = 5 h1 = .InsertItem(h,,"TaskS 3") .AddBar h1,"TaskS",#6/30/2005#,#7/2/2005#,"E" .DefineSummaryBars h,"",h1,"E" .ExpandItem(h) = True End With .EndUpdate End With |
869 |
I want to define/highlight for specified dates as being non-working. Is this possible
With G2antt1 .BeginUpdate .Columns.Add "Items" With .Chart .NonworkingDaysColor = RGB(255,0,0) .PaneWidth(0) = 48 c = .NonworkingDaysColor p = .NonworkingDaysPattern ' .NonworkingDaysPattern .FirstVisibleDate = #1/1/2001# With .Bars.Add("NW") .Color = c .Pattern = p ' p .Height = -1 .Shape = 17 End With End With With .Items h = .AddItem("Item 1") .AddBar h,"NW",#1/2/2001#,#1/3/2001#,"0" .ItemBar(h,"0",29) = False .AddBar h,"Task",#1/2/2001#,#1/4/2001#,"K2" h = .AddItem("Item 2") .AddBar h,"NW",#1/2/2001#,#1/4/2001#,"0" .ItemBar(h,"0",29) = False .AddBar h,"Task",#1/2/2001#,#1/5/2001#,"K2" End With .EndUpdate End With |
868 |
Do you have any sample how can I programmatically magnify a single date, so can show the hours, while the rest of the chart displays days
With G2antt1 .BeginUpdate .MarkSearchColumn = False .ShowFocusRect = False .Columns.Add "Tasks" With .Columns.Add("C") .HeaderAlignment = 1 .Def(0) = True .PartialCheck = True .AllowSizing = False .Width = 18 End With With .Chart .PaneWidth(0) = 96 .AllowCreateBar = 1 .FirstVisibleDate = #6/20/2005# .DrawLevelSeparator = False .LevelCount = 3 .Level(1).DrawGridLines = False .AllowInsideZoom = True .DrawDateTicker = True .DateTickerLabel = "<%mmm%> <%d%><br><b><%hh%>:<%nn%></b>" .MarkSelectDateColor = &H7ffff8ee With .DefaultInsideZoomFormat .OwnerLabel = "<%mmm%> <%d%>" .BackColor = RGB(238,248,255) .BackColorChart = .BackColor .InsideCount = 4 .InsideLabel = "<b><%hh%></b>" End With .InsideZooms.Add #6/22/2005# .DrawGridLines = 2 End With With .Items h = .AddItem("Project 1") .AddBar h,"Summary",#6/21/2005#,#7/1/2005# h1 = .InsertItem(h,,"Task 1") .AddBar h1,"Task",#6/21/2005#,#6/28/2005# .CellMerge(h1,0) = 1 .DefineSummaryBars h,"",h1,"" h1 = .InsertItem(h,,"Task 2") .AddBar h1,"Task",#6/23/2005#,#7/1/2005#,"E" .CellMerge(h1,0) = 1 .DefineSummaryBars h,"",h1,"E" .ItemBar(h1,"E",21) = 5 h1 = .InsertItem(h,,"Task 3") .AddBar h1,"Task",#6/25/2005#,#6/27/2005#,"E" .CellMerge(h1,0) = 1 .DefineSummaryBars h,"",h1,"E" .ExpandItem(h) = True .CellState(h,1) = 1 h = .AddItem("Project 2") .AddBar h,"Summary",#6/26/2005#,#7/6/2005# h1 = .InsertItem(h,,"Task 1") .AddBar h1,"Task",#6/26/2005#,#7/2/2005# .CellMerge(h1,0) = 1 .DefineSummaryBars h,"",h1,"" h1 = .InsertItem(h,,"Task 2") .AddBar h1,"Task",#6/28/2005#,#7/6/2005#,"E" .CellMerge(h1,0) = 1 .DefineSummaryBars h,"",h1,"E" .ItemBar(h1,"E",21) = 5 h1 = .InsertItem(h,,"Task 3") .AddBar h1,"Task",#6/30/2005#,#7/2/2005#,"E" .CellMerge(h1,0) = 1 .DefineSummaryBars h,"",h1,"E" .ExpandItem(h) = True .CellState(h,1) = 1 End With .EndUpdate End With |
867 |
How can I define my own/custom labels and subdivisions
With G2antt1 .BeginUpdate With .Chart .ToolTip = "" .PaneWidth(0) = 0 .ScrollRange(0) = 0 .ScrollRange(1) = 110 .FirstVisibleDate = 0 .ShowNonworkingDates = False .MarkTodayColor = .BackColor .LevelCount = 3 With .Level(0) .ToolTip = "" .Alignment = 1 .Unit = 4096 .Count = 16 .FormatLabel = "'Group <b>'+int(1 +dvalue/16)" End With With .Level(1) .ToolTip = "" .Alignment = 1 .Unit = 4096 .Count = 4 .FormatLabel = " (abs(dvalue)/4) mod 4" .ReplaceLabel("0") = "Sub-Group <b>1</b>" .ReplaceLabel("1") = "Sub-Group <b>2</b>" .ReplaceLabel("2") = "Sub-Group <b>3</b>" .ReplaceLabel("3") = "Sub-Group <b>4</b>" End With With .Level(2) .ToolTip = "" .Unit = 4096 .Count = 1 .FormatLabel = "(abs(dvalue) mod 4)" .ReplaceLabel("0") = "A" .ReplaceLabel("1") = "B" .ReplaceLabel("2") = "C" .ReplaceLabel("3") = "D" End With End With .EndUpdate End With |
866 |
I want to mark or highlight the last Friday of the month. Is there any option to do that
|
865 |
I use the SelectDate method but the dates are not being highligted. What can I do
With G2antt1 .BeginUpdate With .Chart .FirstVisibleDate = #1/1/2008# .MarkTodayColor = .BackColor .LevelCount = 2 .SelectLevel = 1 .SelectDate(#1/2/2008#) = True End With .EndUpdate End With |
864 |
Can I use ebn files to display the selected dates
With G2antt1 .BeginUpdate With .VisualAppearance .Add 2,"c:\exontrol\images\normal.ebn" .Add 1,"CP:2 0 -4 0 4" End With With .Chart .FirstVisibleDate = #1/1/2008# .MarkTodayColor = .BackColor .LevelCount = 2 .MarkSelectDateColor = &H1000000 .SelectLevel = 1 .SelectDate(#1/3/2008#) = True .SelectDate(#1/4/2008#) = True End With .Columns.Add "Default" With .Items .AddBar .AddItem("Item 1"),"Task",#1/2/2008#,#1/6/2008# .AddBar .AddItem("Item 2"),"Task",#1/3/2008#,#1/7/2008# .AddBar .AddItem("Item 3"),"Task",#1/4/2008#,#1/8/2008# .AddBar .AddItem("Item 4"),"Task",#1/5/2008#,#1/9/2008# End With .EndUpdate End With |
863 |
Can I use ebn files to display the selected dates
With G2antt1 .BeginUpdate .VisualAppearance.Add 1,"c:\exontrol\images\normal.ebn" With .Chart .FirstVisibleDate = #1/1/2008# .MarkTodayColor = .BackColor .LevelCount = 2 .MarkSelectDateColor = &H1000000 .SelectLevel = 1 .SelectDate(#1/3/2008#) = True End With .Columns.Add "Default" With .Items .AddBar .AddItem("Item 1"),"Task",#1/2/2008#,#1/6/2008# .AddBar .AddItem("Item 2"),"Task",#1/3/2008#,#1/7/2008# .AddBar .AddItem("Item 3"),"Task",#1/4/2008#,#1/8/2008# End With .EndUpdate End With |
862 |
How can I change the color for selected dates to be solid
With G2antt1 .BeginUpdate With .Chart .PaneWidth(False) = 0 .FirstVisibleDate = #1/1/2008# .MarkTodayColor = .BackColor .LevelCount = 2 .MarkSelectDateColor = &H7fff0000 .SelectLevel = 1 .SelectDate(#1/15/2008#) = True .SelectDate(#1/16/2008#) = True End With .EndUpdate End With |
861 |
How can I disable selecting dates when I click the chart's header
With G2antt1 .Chart.AllowSelectDate = False End With |
860 |
Is there any option to specify which dates can be magnified or resized
With G2antt1 .BeginUpdate With .Chart .LevelCount = 2 .FirstVisibleDate = #1/1/2008# .AllowInsideZoom = True .ShowNonworkingDates = True .CondInsideZoom = "not(weekday(value) = 0 or weekday(value) = 6)" End With .EndUpdate End With |
859 |
How can I change the width for a specified date time unit
With G2antt1 .BeginUpdate With .Chart .LevelCount = 2 .FirstVisibleDate = #1/1/2008# .AllowInsideZoom = True .AllowResizeInsideZoom = False .InsideZoomOnDblClick = False With .InsideZooms With .Add(#1/4/2008#) .Width = 32 .AllowInsideFormat = False End With End With End With .EndUpdate End With |
858 |
How can I disable the control's splitter so the user can't resize the list area
|
857 |
How can I disable the control's splitter so the user can't resize the chart area
|
856 |
How can I change the label for a specified unit
With G2antt1 .BeginUpdate With .Chart .PaneWidth(0) = 0 .LevelCount = 2 .FirstVisibleDate = #1/1/2008# .AllowInsideZoom = True .AllowResizeInsideZoom = False .InsideZoomOnDblClick = False .DefaultInsideZoomFormat.OwnerLabel = "<b><%d%></b> <%d2%>" With .InsideZooms .SplitBaseLevel = False .DefaultWidth = 32 .Add(#1/4/2008#).AllowInsideFormat = False End With End With .EndUpdate End With |
855 |
How can I bold the inside units
With G2antt1 .BeginUpdate With .Chart .PaneWidth(0) = 0 .LevelCount = 2 .FirstVisibleDate = #1/1/2008# .AllowInsideZoom = True .AllowResizeInsideZoom = False .InsideZoomOnDblClick = False .DefaultInsideZoomFormat.InsideLabel = "<b><%hh%></b>" .InsideZooms.Add #1/4/2008# End With .EndUpdate End With |
854 |
How can I change the scale unit when doing inside zoom ( the chart displays weeks, and we want week days )
With G2antt1 .BeginUpdate With .Chart .ShowNonworkingDates = False .PaneWidth(0) = 0 .LevelCount = 2 With .Level(0) .Label = "<%mmmm%>" .Unit = 16 End With With .Level(1) .Label = "<%ww%>" .Unit = 256 End With .FirstVisibleDate = #1/1/2008# .AllowInsideZoom = True With .DefaultInsideZoomFormat .OwnerLabel = "<font ;7><%mmm%> Week: <%ww%>" .InsideLabel = "<font ;7><b><%d1%></b>" .InsideUnit = 4096 End With With .InsideZooms .SplitBaseLevel = False .Add #2/3/2008# End With End With .EndUpdate End With |
853 |
How can I zoom or magnify the selected date to display the hours, from 8 to 8
With G2antt1 .BeginUpdate With .Chart .PaneWidth(0) = 0 .LevelCount = 2 .FirstVisibleDate = #1/1/2008# .AllowInsideZoom = True With .DefaultInsideZoomFormat .InsideLabel = "H: <b><%hh%></b>" .InsideUnit = 65536 .InsideCount = 8 End With With .InsideZooms .Add #1/4/2008# End With End With .EndUpdate End With |
852 |
How can I zoom or magnify the selected date to display the hours
With G2antt1 .BeginUpdate With .Chart .PaneWidth(0) = 0 .LevelCount = 2 .FirstVisibleDate = #1/1/2008# .AllowInsideZoom = True With .InsideZooms .Add #1/4/2008# End With End With .EndUpdate End With |
851 |
How can I change the foreground color for a time unit
With G2antt1 .BeginUpdate With .Chart .LevelCount = 2 .FirstVisibleDate = #1/1/2008# .AllowInsideZoom = True .AllowResizeInsideZoom = False .InsideZoomOnDblClick = False .DefaultInsideZoomFormat.ForeColor = RGB(255,0,0) With .InsideZooms .SplitBaseLevel = False .DefaultWidth = 18 .Add(#1/4/2008#).AllowInsideFormat = False End With End With .EndUpdate End With |
850 |
How can I change the background color for a time unit, in the chart area
With G2antt1 .BeginUpdate With .Chart .LevelCount = 2 .FirstVisibleDate = #1/1/2008# .AllowInsideZoom = True .AllowResizeInsideZoom = False .InsideZoomOnDblClick = False .DefaultInsideZoomFormat.BackColorChart = RGB(255,0,0) With .InsideZooms .SplitBaseLevel = False .DefaultWidth = 18 .Add(#1/4/2008#).AllowInsideFormat = False End With End With .EndUpdate End With |
849 |
How can I change the background color for a time unit, using EBN files
With G2antt1 .BeginUpdate .VisualAppearance.Add 1,"c:\exontrol\images\normal.ebn" With .Chart .LevelCount = 2 .FirstVisibleDate = #1/1/2008# .AllowInsideZoom = True .AllowResizeInsideZoom = False .InsideZoomOnDblClick = False .DefaultInsideZoomFormat.BackColor = &H1000000 With .InsideZooms .SplitBaseLevel = False .DefaultWidth = 18 .Add(#1/4/2008#).AllowInsideFormat = False End With End With .EndUpdate End With |
848 |
How can I change the background color for a time unit
With G2antt1 .BeginUpdate With .Chart .LevelCount = 2 .FirstVisibleDate = #1/1/2008# .AllowInsideZoom = True .AllowResizeInsideZoom = False .InsideZoomOnDblClick = False .DefaultInsideZoomFormat.BackColor = RGB(255,0,0) With .InsideZooms .SplitBaseLevel = False .DefaultWidth = 18 .Add(#1/4/2008#).AllowInsideFormat = False End With End With .EndUpdate End With |
847 |
How can I display the column using currency format and enlarge the font for certain values
With G2antt1 With .Columns.Add("Currency") .Def(17) = 1 .FormatColumn = "len(value) ? ((0:=dbl(value)) < 10 ? '<fgcolor=808080><font ;7>' : '<b>') + currency(=:0)" End With With .Items .AddItem "1.23" .AddItem "2.34" .AddItem "9.94" .AddItem "11.94" .AddItem "1000" End With End With |
846 |
How can I highlight only parts of the cells
With G2antt1 With .Columns.Add("") .Def(17) = 1 .FormatColumn = "value replace 'hil' with '<fgcolor=FF0000><b>hil</b></fgcolor>'" End With With .Items h = .AddItem("Root") .InsertItem h,,"Child 1" .InsertItem h,,"Child 2" .InsertItem h,,"Child 3" .ExpandItem(h) = True End With End With |
845 |
How can I get the number of occurrences of a specified string in the cell
With G2antt1 .Columns.Add "" With .Columns.Add("occurrences") .ComputedField = "lower(%0) count 'o'" .FormatColumn = "'contains ' + value + ' of \'o\' chars'" End With With .Items h = .AddItem("Root") .InsertItem h,,"Child 1 oooof the root" .InsertItem h,,"Child 2" .InsertItem h,,"Child 3" .ExpandItem(h) = True End With End With |
844 |
How can I display dates in my format
With G2antt1 With .Columns.Add("Date") .Def(17) = 1 .FormatColumn = "'<b>' + year(0:=date(value)) + '</b><fgcolor=808080><font ;6> (' + month(=:0) + ' - ' + day(=:0) +')'" End With With .Items .AddItem #1/21/2001# .AddItem #2/22/2002# .AddItem #3/13/2003# .AddItem #4/24/2004# End With End With |
843 |
How can I display dates in short format
With G2antt1 .Columns.Add("Date").FormatColumn = "shortdate(value)" With .Items .AddItem #1/1/2001# .AddItem #2/2/2002# .AddItem #3/3/2003# .AddItem #4/4/2004# End With End With |
842 |
How can I display dates in long format
With G2antt1 .Columns.Add("Date").FormatColumn = "longdate(value)" With .Items .AddItem #1/1/2001# .AddItem #2/2/2002# .AddItem #3/3/2003# .AddItem #4/4/2004# End With End With |
841 |
How can I display only the right part of the cell
With G2antt1 .Columns.Add "" With .Columns.Add("Right") .ComputedField = "%0 right 2" .FormatColumn = "'""' + value + '""'" End With With .Items h = .AddItem("Root") .InsertItem h,,"Child 1" .InsertItem h,,"Child 2" .InsertItem h,,"SChild 3" .ExpandItem(h) = True End With End With |
840 |
How can I display only the left part of the cell
With G2antt1 .Columns.Add "" .Columns.Add("Left").ComputedField = "%0 left 2" With .Items h = .AddItem("Root") .InsertItem h,,"Child 1" .InsertItem h,,"Child 2" .InsertItem h,,"SChild 3" .ExpandItem(h) = True End With End With |
839 |
How can I display true or false instead 0 and -1
With G2antt1 .Columns.Add("Boolean").FormatColumn = "value != 0 ? 'true' : 'false'" With .Items .AddItem True .AddItem False .AddItem True .AddItem 0 .AddItem 1 End With End With |
838 |
Is there any option to print the columns section on each page
With G2antt1 .BeginUpdate .Columns.Add "Task" .Chart.FirstVisibleDate = #1/1/2001# .Chart.LevelCount = 2 With .Items h1 = .AddItem("Task 1") .AddBar h1,"Task",#1/2/2001#,#1/4/2001#,"K1" h2 = .AddItem("Task 2") .AddBar h2,"Task",#2/5/2001#,#2/7/2001#,"K2" .AddLink "L1",h1,"K1",h2,"K2" .Link("L1",6) = 0 End With .EndUpdate With CreateObject("Exontrol.Print") .Options = "ColumnsOnEveryPage=1" .PrintExt = G2antt1.Object .Preview End With End With |
837 |
How do I print the control's content
With G2antt1 .BeginUpdate .Columns.Add "Task" .Chart.FirstVisibleDate = #1/1/2001# With .Items h1 = .AddItem("Task 1") .AddBar h1,"Task",#1/2/2001#,#1/4/2001#,"K1" h2 = .AddItem("Task 2") .AddBar h2,"Task",#1/5/2001#,#1/7/2001#,"K2" .AddLink "L1",h1,"K1",h2,"K2" .Link("L1",6) = 0 End With .EndUpdate With CreateObject("Exontrol.Print") .PrintExt = G2antt1.Object .Preview End With End With |
836 |
How can I display icons or images instead numbers
With G2antt1 .Images "gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTq" & _ "lVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m" & _ "0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/y" & _ "NAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=" With .Columns.Add("Icons") .Def(17) = 1 .FormatColumn = "'The cell displays the icon <img>'+value+'</img> instead ' + value" End With With .Items .AddItem 1 .AddItem 2 .AddItem 3 End With End With |
835 |
How can I display the column using currency
With G2antt1 .Columns.Add("Currency").FormatColumn = "currency(dbl(value))" With .Items .AddItem "1.23" .AddItem "2.34" .AddItem "0" .AddItem 5 .AddItem "10000.99" End With End With |
834 |
How can I display the currency only for not empty cells
With G2antt1 .Columns.Add "Number" .Columns.Add("Currency").ComputedField = "len(%0) ? currency(dbl(%0)) : ''" With .Items .AddItem "1.23" .AddItem "2.34" .AddItem "0" .ItemBackColor(.AddItem()) = RGB(255,128,128) .AddItem "10000.99" End With End With |
833 |
Is there a function to display the number of days between two date including the number of hours
With G2antt1 .Columns.Add("Start").Width = 32 .Columns.Add "End" .Columns.Add("Duration").ComputedField = "((1:=int(0:= (date(%1)-date(%0)))) != 0 ? (=:1 + ' day(s)') : '') + (=:1 ? ' ' : '' ) + ((1:=int(0:=((=:0 - =:1 + 1/24/60/60/2)" & _ "*24))) != 0 ? =:1 + ' hour(s) ' : '' ) + ((1:=round((=:0 - =:1)*60)) != 0 ? =:1 + ' min(s)' : '')" With .Items h = .AddItem(#1/11/2001#) .CellValue(h,1) = #1/14/2001# h = .AddItem(#2/22/2002 0:00:00 PM#) .CellValue(h,1) = #3/14/2002 1:00:00 PM# h = .AddItem(#3/13/2003#) .CellValue(h,1) = #4/11/2003 11:00:00 AM# End With End With |
832 |
Is there a function to display the number of days between two date including the number of hours
With G2antt1 .Columns.Add "Start" .Columns.Add "End" .Columns.Add("Duration").ComputedField = """D "" + int(date(%1)-date(%0)) + "" H "" + round(24*(date(%1)-date(%0) - floor(date(%1)-date(%0))))" With .Items h = .AddItem(#1/11/2001#) .CellValue(h,1) = #1/14/2001 11:00:00 PM# h = .AddItem(#2/22/2002 0:00:00 PM#) .CellValue(h,1) = #3/14/2002 1:00:00 PM# h = .AddItem(#3/13/2003#) .CellValue(h,1) = #4/11/2003 11:00:00 AM# End With End With |
831 |
How can I display the number of days between two dates
With G2antt1 .Columns.Add "Start" .Columns.Add "End" .Columns.Add("Duration").ComputedField = "(date(%1)-date(%0)) + ' days'" With .Items h = .AddItem(#1/11/2001#) .CellValue(h,1) = #1/14/2001# h = .AddItem(#2/22/2002#) .CellValue(h,1) = #3/14/2002# h = .AddItem(#3/13/2003#) .CellValue(h,1) = #4/11/2003# End With End With |
830 |
How can I get second part of the date
With G2antt1 .Columns.Add "Date" .Columns.Add("Second").ComputedField = "sec(date(%0))" With .Items .AddItem #1/11/2001 10:10:00 AM# .AddItem #2/22/2002 11:01:22 AM# .AddItem #3/13/2003 0:23:01 PM# .AddItem #4/14/2004 1:11:59 PM# End With End With |
829 |
How can I get minute part of the date
With G2antt1 .Columns.Add "Date" .Columns.Add("Minute").ComputedField = "min(date(%0))" With .Items .AddItem #1/11/2001 10:10:00 AM# .AddItem #2/22/2002 11:01:00 AM# .AddItem #3/13/2003 0:23:00 PM# .AddItem #4/14/2004 1:11:00 PM# End With End With |
828 |
How can I check the hour part only so I know it was afternoon
With G2antt1 .ConditionalFormats.Add("hour(%0)>=12").Bold = True .Columns.Add "Date" .Columns.Add("Hour").ComputedField = "hour(%0)" With .Items .AddItem #1/11/2001 10:00:00 AM# .AddItem #2/22/2002 11:00:00 AM# .AddItem #3/13/2003 0:00:00 PM# .AddItem #4/14/2004 1:00:00 PM# End With End With |
827 |
What about a function to get the day in the week, or days since Sunday
With G2antt1 .Columns.Add "Date" .Columns.Add("WeekDay").ComputedField = "weekday(%0)" With .Items .AddItem #1/11/2001 10:00:00 AM# .AddItem #2/22/2002 11:00:00 AM# .AddItem #3/13/2003 0:00:00 PM# .AddItem #4/14/2004 1:00:00 PM# End With End With |
826 |
Is there any function to get the day of the year or number of days since January 1st
With G2antt1 .Columns.Add "Date" .Columns.Add("Day since January 1st").ComputedField = "yearday(%0)" With .Items .AddItem #1/11/2001 10:00:00 AM# .AddItem #2/22/2002 11:00:00 AM# .AddItem #3/13/2003 0:00:00 PM# .AddItem #4/14/2004 1:00:00 PM# End With End With |
825 |
How can I display only the day of the date
With G2antt1 .Columns.Add "Date" .Columns.Add("Day").ComputedField = "day(%0)" With .Items .AddItem #1/11/2001 10:00:00 AM# .AddItem #2/22/2002 11:00:00 AM# .AddItem #3/13/2003 0:00:00 PM# .AddItem #4/14/2004 1:00:00 PM# End With End With |
824 |
How can I display only the month of the date
With G2antt1 .Columns.Add "Date" .Columns.Add("Month").ComputedField = "month(%0)" With .Items .AddItem #1/1/2001 10:00:00 AM# .AddItem #2/2/2002 11:00:00 AM# .AddItem #3/3/2003 0:00:00 PM# .AddItem #4/4/2004 1:00:00 PM# End With End With |
823 |
How can I get only the year part from a date expression
With G2antt1 .Columns.Add "Date" .Columns.Add("Year").ComputedField = "year(%0)" With .Items .AddItem #1/1/2001 10:00:00 AM# .AddItem #2/2/2002 11:00:00 AM# .AddItem #3/3/2003 0:00:00 PM# .AddItem #4/4/2004 1:00:00 PM# End With End With |
822 |
Can I convert the expression to date
With G2antt1 .Columns.Add "Number" .Columns.Add("Date").ComputedField = "date(dbl(%0))" With .Items .AddItem "-1.98" .AddItem "30000.99" .AddItem "3561.23" .AddItem "1232.34" End With End With |
821 |
Can I convert the expression to a number, double or float
With G2antt1 .Columns.Add "Number" .Columns.Add("Number + 2").ComputedField = "dbl(%0)+2" With .Items .AddItem "-1.98" .AddItem "0.99" .AddItem "1.23" .AddItem "2.34" End With End With |
820 |
How can I display dates in long format
With G2antt1 .Columns.Add "Date" .Columns.Add("LongFormat").ComputedField = "longdate(%0)" With .Items .AddItem #1/1/2001 10:00:00 AM# .AddItem #2/2/2002 11:00:00 AM# .AddItem #3/3/2003 0:00:00 PM# .AddItem #4/4/2004 1:00:00 PM# End With End With |
819 |
How can I display dates in short format
With G2antt1 .Columns.Add "Date" .Columns.Add("ShortFormat").ComputedField = "shortdate(%0)" With .Items .AddItem #1/1/2001 10:00:00 AM# .AddItem #2/2/2002 11:00:00 AM# .AddItem #3/3/2003 0:00:00 PM# .AddItem #4/4/2004 1:00:00 PM# End With End With |
818 |
How can I display the time only of a date expression
With G2antt1 .Columns.Add "Date" .Columns.Add("Time").ComputedField = "'time is:' + time(date(%0))" With .Items .AddItem #1/1/2001 10:00:00 AM# .AddItem #2/2/2002 11:00:00 AM# .AddItem #3/3/2003 0:00:00 PM# .AddItem #4/4/2004 1:00:00 PM# End With End With |
817 |
Is there any function to display currencies, or money formatted as in the control panel
With G2antt1 .Columns.Add "Number" .Columns.Add("Currency").ComputedField = "currency(dbl(%0))" With .Items .AddItem 1.23 .AddItem 2.34 .AddItem 10000.99 End With End With |
816 |
How can I convert the expression to a string so I can look into the date string expression for month's name
With G2antt1 .Columns.Add "Number" .Columns.Add("Str").ComputedField = "str(%0) + ' AA'" With .Items .AddItem "-1.98" .AddItem "0.99" .AddItem "1.23" .AddItem "2.34" End With End With |
815 |
Can I display the absolute value or positive part of the number
With G2antt1 .Columns.Add "Number" .Columns.Add("Abs").ComputedField = "abs(%0)" With .Items .AddItem "-1.98" .AddItem "0.99" .AddItem "1.23" .AddItem "2.34" End With End With |
814 |
Is there any function to get largest number with no fraction part that is not greater than the value
With G2antt1 .Columns.Add "Number" .Columns.Add("Floor").ComputedField = "floor(%0)" With .Items .AddItem "-1.98" .AddItem "0.99" .AddItem "1.23" .AddItem "2.34" End With End With |
813 |
Is there any function to round the values base on the .5 value
With G2antt1 .Columns.Add "Number" .Columns.Add("Round").ComputedField = "round(%0)" With .Items .AddItem "-1.98" .AddItem "0.99" .AddItem "1.23" .AddItem "2.34" End With End With |
812 |
How can I get or display the integer part of the cell
With G2antt1 .Columns.Add "Number" .Columns.Add("Int").ComputedField = "int(%0)" With .Items .AddItem "-1.98" .AddItem "0.99" .AddItem "1.23" .AddItem "2.34" End With End With |
811 |
How can I display names as proper ( first leter of the word must be in uppercase, and the rest in lowercase )
With G2antt1 .Columns.Add("").FormatColumn = "proper(%0)" With .Items h = .AddItem("root") .InsertItem h,,"child child" .InsertItem h,,"child child" .InsertItem h,,"child child" .ExpandItem(h) = True End With End With |
810 |
Is there any option to display cells in uppercase
With G2antt1 .Columns.Add("").FormatColumn = "upper(%0)" With .Items h = .AddItem("Root") .InsertItem h,,"Child 1" .InsertItem h,,"Child 2" .InsertItem h,,"Chld 3" .ExpandItem(h) = True End With End With |
809 |
Is there any option to display cells in lowercase
With G2antt1 .Columns.Add("").FormatColumn = "lower(%0)" With .Items h = .AddItem("Root") .InsertItem h,,"Child 1" .InsertItem h,,"Child 2" .InsertItem h,,"Chld 3" .ExpandItem(h) = True End With End With |
808 |
How can I mark the cells that has a specified type, ie strings only
With G2antt1 .ConditionalFormats.Add("type(%0) = 8").ForeColor = RGB(255,0,0) .Columns.Add "" With .Items h = .AddItem("Root") .InsertItem h,,"Child 1" .InsertItem h,,2 .InsertItem h,,"Chld 3" .ExpandItem(h) = True End With End With |
807 |
How can I bold the items that contains data or those who displays empty strings
With G2antt1 .ConditionalFormats.Add("not len(%1)=0").Bold = True .Columns.Add "C1" .Columns.Add "C2" With .Items h = .AddItem("Root") .InsertItem h,,"Child 1" hC = .InsertItem(h,,"Child 2") .CellValue(hC,1) = "1" .InsertItem h,,"Child 3" .ExpandItem(h) = True End With End With |
806 |
Can I change the background color for items or cells that contains a specified string
With G2antt1 .ConditionalFormats.Add("%0 contains 'hi'").BackColor = RGB(255,0,0) .Columns.Add "" With .Items h = .AddItem("Root") .InsertItem h,,"Child 1" .InsertItem h,,"Child 2" .InsertItem h,,"Chld 3" .ExpandItem(h) = True End With End With |
805 |
Is there any option to change the fore color for cells or items that ends with a specified string
With G2antt1 .ConditionalFormats.Add("%0 endwith '22'").ForeColor = RGB(255,0,0) .Columns.Add "" With .Items h = .AddItem("Root") .InsertItem h,,"Child 1" .InsertItem h,,"Child 1.22" .InsertItem h,,"Child 2.22" .ExpandItem(h) = True End With End With |
804 |
How can I highlight the cells or items that starts with a specified string
With G2antt1 .ConditionalFormats.Add("%0 startwith 'C'").Underline = True .Columns.Add "" With .Items h = .AddItem("Root") .InsertItem h,,"Child 1" .InsertItem h,,"Child 2" .InsertItem h,,"SChild 3" .ExpandItem(h) = True End With End With |
803 |
How can I change the background color or the visual appearance using ebn for a particular column
With G2antt1 .VisualAppearance.Add 1,"c:\exontrol\images\normal.ebn" With .Columns .Add "Column 1" .Add("Column 2").Def(7) = 16777216 .Add("Column 3").Def(7) = 16777471 .Add "Column 4" End With End With |
802 |
How can I change the foreground color for a particular column
|
801 |
How can I change the background color for a particular column
|